<?php $form=$this->beginWidget('booster.widgets.TbActiveForm',array(
	'id'=>'usuarios-form',
	'enableAjaxValidation'=>false,
)); ?>

<p class="help-block">Fields with <span class="required">*</span> are required.</p>

<?php echo $form->errorSummary($model); ?>

	<?php echo $form->textFieldGroup($model,'usuario',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>255)))); ?>

	<?php //echo $form->textFieldGroup($model,'contrasena',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>50)))); ?>

	<?php echo $form->textFieldGroup($model,'correo',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>255)))); ?>

	<?php //echo $form->textFieldGroup($model,'creado_el',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>

	<?php //echo $form->textFieldGroup($model,'actualizado_el',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>

	<?php //echo $form->checkBoxGroup($model,'esta_activo'); ?>

	<?php //echo $form->checkBoxGroup($model,'esta_deshabilitado'); ?>

	<?php //echo $form->checkBoxGroup($model,'correo_verificado'); ?>

	<?php //echo $form->textFieldGroup($model,'llave_activacion',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>255)))); ?>

	<?php //echo $form->textFieldGroup($model,'ultima_visita_el',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>

	<?php echo $form->textFieldGroup($model,'nombre',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>255)))); ?>

	<?php echo $form->textFieldGroup($model,'apellido',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>255)))); ?>

	<?php echo $form->textFieldGroup($model,'cedula',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>255)))); ?>
	
	<?php //echo $form->textFieldGroup($model,'unidad_administrativa',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>255)))); 
		echo $form->dropDownListGroup($model,'unidad_administrativa',
										array(
											'wrapperHtmlOptions' => array(
												'class' => 'col-sm-5',
											),
											'label'=>Yii::t('msg','Unidad administrativa del usuario'),
											'widgetOptions' => array(
												//'id'=>'partida',
												//'name'=>'partida',
												'data' =>array('0'=>'Eureka','1'=>'Polar','2'=>'Zoom'),
												//'options'=>array($model->proyecto_id => array('selected'=>true)),
												'htmlOptions' => array('id'=>'rol', 'prompt' => 'Seleccionar unidad administrativa', 'class'=>'span5','maxlength'=>255, 
																		),
											),
											//'hint' => 'Tipo de archivo a cargar.'
										));

	?>
	
	<?php //echo $form->textFieldGroup($model,'cargo',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>255)))); 
		echo $form->dropDownListGroup($model,'cargo',
										array(
											'wrapperHtmlOptions' => array(
												'class' => 'col-sm-5',
											),
											'label'=>Yii::t('msg','Cargo del usuario'),
											'widgetOptions' => array(
												//'id'=>'partida',
												//'name'=>'partida',
												'data' =>array(),
												//'options'=>array($model->proyecto_id => array('selected'=>true)),
												'htmlOptions' => array('id'=>'rol', 'prompt' => 'Seleccionar cargo', 'class'=>'span5','maxlength'=>255, 
																		),
											),
											//'hint' => 'Tipo de archivo a cargar.'
										));

	?>

	<?php //echo $form->textFieldGroup($model,'rol',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); 
		echo $form->dropDownListGroup($model,'rol',
										array(
											'wrapperHtmlOptions' => array(
												'class' => 'col-sm-5',
											),
											'label'=>Yii::t('msg','Rol de usuario'),
											'widgetOptions' => array(
												//'id'=>'partida',
												//'name'=>'partida',
												'data' =>array('admin' => "Administrador", 'coord' => "Coordinador", 'perio' => "Periodista"),
												//'options'=>array($model->proyecto_id => array('selected'=>true)),
												'htmlOptions' => array('id'=>'rol', 'prompt' => 'Seleccionar rol', 'class'=>'span5','maxlength'=>255, 
																		),
											),
											//'hint' => 'Tipo de archivo a cargar.'
										));

	?>

<div class="form-actions">
	<?php $this->widget('booster.widgets.TbButton', array(
			'buttonType'=>'submit',
			'context'=>'primary',
			'label'=>$model->isNewRecord ? 'Create' : 'Save',
		)); ?>
</div>

<?php $this->endWidget(); ?>
